
 layui.use('carousel', function(){
  var carousel = layui.carousel;
  //建造实例
  carousel.render({
    elem: '#test1'
    ,width: '100%' //设置容器宽度
    ,arrow: 'always' //始终显示箭头
    ,height:'460px'
    ,anim:'fade'
    // ,anim: 'updown' //切换动画方式
  });
});


// 手机
var phone = "";
for (var i = 1; i <= 8; i++){
  phone += '<li class="phone-li">'+
    '<a href="">'+
    '<img class="phone-img" src="../小米/images/ia_'+i+'.webp" alt="">'+
    '<h4 class="phone-h4">小米10 至尊版</h4>'+
    '<p class="phone-p">120x 变焦/120w秒充/120HZ屏幕</p>'+
    '<span class="phone-span">599元起</span>'+
   '</a>'+
    '</li>';
}
$(".phone-ul").append(phone);

window.onload=function(){
  var showli = document.getElementById("showleft");
  var hiddediv = document.getElementById("hiddenLeft");
  showli.onmouseenter= function () {
    hiddediv.style.display = "block";
  }
  showli.onmouseout = function () {
    hiddediv.style.display = "none";
  }
}
